﻿@model List<Stardust.Models.ReservaBean>

<h2>Lista de Reservas</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validationEngine-en.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validationEngine.js")" type="text/javascript"></script>
    
@using (Html.BeginForm("Listar", "Pago", FormMethod.Post, new { @class = "form", id = "validate" }))
{ 
    <p></p><p></p><p></p><p></p>

    <div class="wrapper">
    <div class="widget">
      <div class="title">
      <h6>Lista de Reservas</h6>
      </div>
      <div class="dataTables_wrapper">

        <table cellpadding = "0" cellspacing = "0" border="0" width = "100%" class = "display"> @*cambiar*@
        <thead>
        <tr>
            <th class="ui-state-default" rowspan="1" colspan="1" style="width:160px;">
                <div class="DataTables_sort_wrapper">
                Fecha Llegada
                <span class="DataTables_sort_icon css_right ui-icon ui-icon-triangle-1-s"></span>
                </div>
             </th>
            <th class="ui-state-default" rowspan="1" colspan="1" style="width:160px;" >
                <div class="DataTables_sort_wrapper">
                Fecha Salida
                <span class="DataTables_sort_icon css_right ui-icon ui-icon-triangle-1-s"></span>
                </div>
             </th>
               <th class="ui-state-default" rowspan="1" colspan="1" style="width:120px;" >
                <div class="DataTables_sort_wrapper">
                Pago Inicial
                <span class="DataTables_sort_icon css_right ui-icon ui-icon-triangle-1-s"></span>
                </div>
             </th>
               <th class="ui-state-default" rowspan="1" colspan="1" style="width:120px;" >
                <div class="DataTables_sort_wrapper">
                Monto a Pagar
                <span class="DataTables_sort_icon css_right ui-icon ui-icon-triangle-1-s"></span>
                </div>
             </th>
             <th class="ui-state-default" rowspan="1" colspan="1">

             </th>
        </tr>
    </thead>

        <tbody>
            @for (int i = 0; i < Model.Count; i++)
            {
                @Html.HiddenFor(model => model[i].id)
         
             <tr class="gradeA odd">       
                
                <td>@Html.DisplayFor(model => model[i].fechaRegistro)</td>
                <td>@Html.DisplayFor(model => model[i].fechaCheckOut)</td>
                <td>@Html.DisplayFor(model => model[i].pagoIni)</td>
                <td>@Html.DisplayFor(model => model[i].total)</td>  
                <td>
                    <a href="@Url.Action("PagoHabContado", new { id = Model[i].id })"><img src="../../Content/images/icons/color/cash.png", alt="Cash" />Contado </a> |                    
                    <a href="@Url.Action("PagoHabCredito", new { id = Model[i].id })"><img src="../../Content/images/icons/color/credit.png", alt="Credit" />Credito </a>
                </td>
             </tr>

            }

    
    </tbody>
        </table>

      </div>
        
    </div>
    </div>
    

    <p></p><p></p><p></p><p></p>
    <p>
        <input type="submit" value="Guardar" class = "redB" />
        @Html.ActionLink("Regresar", "../Home/Index")
    </p>
 }
